<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>高级查询产品信息</title>
</head>
<body>
<script>
    $(function () {
        $("#ProR-save-hlq").linkbutton({onClick:function () {
                var queryParams = $("#proRdg").datagrid('options').queryParams;
                queryParams.pname=$("#hut-pname-hlq-r").val();
                queryParams.pcategory = $("#hut-pcategory-hlq-r").val();
                queryParams.startpbirthday = $("#hut-startpbirthday-hlq-r").val();
                queryParams.endpbirthday = $("#hut-endpbirthday-hlq-r").val();
                queryParams.startpouttime = $("#hut-startpouttime-hlq-r").val();
                queryParams.endpouttime = $("#hut-endpouttime-hlq-r").val();
                queryParams.pcompany = $("#hut-pcompany-hlq-r").val();
                queryParams.pprice = $("#hut-pprice-hlq-r").val();
                queryParams.poprice =  $("#hut-poprice-hlq-r").val();
                queryParams.pspec = $("#hut-pspec-hlq-r").val();
                queryParams.pwunit = $("#hut-pwunit-hlq-r").val();
                queryParams.ptype = $("#hut-ptype-hlq-r").val();
                queryParams.startpstock = $("#hut-startpstock-hlq-r").val();
                queryParams.endpstock = $("#hut-endpstock-hlq-r").val();
                $("#proRdg").datagrid({
                    url:'ProR-form-hlq-sub',
                    method:'post'
                });
                $("#hlQueryproR").dialog("close");
                $("#proRdg").datagrid("reload");
            }});

        $("#ProR-close-hlq").linkbutton({onClick:function () {
                $("#hlQueryproR").dialog("close");
            }});

        $("#hut-pcategory-hlq-r").combobox({
            onBeforeLoad: function(param){
                if(param == null || param.q == null || param.q.replace(/ /g, '') == ''){
                    var value = $(this).combobox('getValue');
                    if(value){// 修改的时候才会出现q为空而value不为空
                        param.id = value;
                        return true;
                    }
                    return false;
                }

            }});
    });
</script>
<div>
    <form id="ProR-form-hlq" action="" method="">
        <div class="div-title-hut"> ----------------------------<span class="span-title">产品信息</span>------------------------------</div>
        <div class="ddt">
            <input id="hut-pname-hlq-r" name="pname" class="easyui-textbox" data-options="label:'产品名称',width:450">
        </div>
        <div class="ddt">
            <input id="hut-pcategory-hlq-r" name="pcategory" class="easyui-combobox" data-options="required:false,prompt:'模糊编号及分类名',url:'getAllCategoryBymh',
        label:'产品分类',valueField:'pcid',textField:'pcname',method:'post',editable:true,panelHeight:'auto',width:300,mode:'remote'" ><div style="width: 25px;display: inline-block"></div>
            <input  id="hut-pcompany-hlq-r" name="pcompany" class="easyui-textbox" data-options="label:'产品厂家',width:300">
        </div>
        <div class="ddt">
            <input id="hut-poprice-hlq-r" name="pprice" class="easyui-textbox" data-options="label:'产品成本价格',width:300"><div style="width: 25px;display: inline-block"></div>
            <input id="hut-pprice-hlq-r" name="poprice" class="easyui-textbox" data-options="label:'产品销售价格',width:300">
        </div>
        <div class="ddt">
            <input id="hut-startpbirthday-hlq-r" name="startpbirthday" class="easyui-datebox" data-options="label:'产品生产日期(起始)',width:300"><div style="width: 25px;display: inline-block"></div>
            <input id="hut-endpbirthday-hlq-r" name="endpbirthday" class="easyui-datebox" data-options="label:'产品生产日期(结束)',width:300">
        </div>
        <div class="ddt">
            <input id="hut-startpouttime-hlq-r" name="startpouttime" class="easyui-datebox" data-options="label:'产品失效日期(起始)',width:300"><div style="width: 25px;display: inline-block"></div>
            <input id="hut-endpouttime-hlq-r" name="endpouttime" class="easyui-datebox" data-options="label:'产品失效日期(结束)',width:300">
        </div>
        <div class="ddt">
            <input id="hut-startpstock-hlq-r" name="startpstock" class="easyui-textbox" data-options="label:'产品最小库存数',width:300"><div style="width: 25px;display: inline-block"></div>
            <input id="hut-endpstock-hlq-r" name="endpstock" class="easyui-textbox" data-options="label:'产品最大库存数',width:300">
        </div>
        <div style="text-align: center; ">
            <input id="hut-ptype-hlq-r" name="ptype" class="easyui-textbox" data-options="label:'产品型号',width:180"><div style="width: 25px;display: inline-block"></div>
            <input id="hut-pspec-hlq-r" name="pspec" class="easyui-textbox" data-options="label:'产品规格',width:180"><div style="width: 25px;display: inline-block"></div>
            <input id="hut-pwunit-hlq-r" name="pwunit" class="easyui-textbox" data-options="label:'产品单位',width:180">
        </div>
        <div class="btn" style="text-align: center;margin:50px">
            <a id="ProR-save-hlq" class="easyui-linkbutton " data-options="iconCls:'icon-ok2'">开始查询</a>
            <a id="ProR-close-hlq" class="easyui-linkbutton" data-options="iconCls:'icon-cancel2'">取消查询</a>
        </div>
    </form>
</div>
</body>
</html>
